<%@ page contentType="text/html;charset=utf-8"%>
<jsp:useBean id="computer" class="tom.jiafei.ComputerBean" scope="session"/>

<html>
<head>
	<title>computerBean</title>
</head>
<body bgcolor="#AAFF99">
<form action="" method="post" name="form">
	<input type="text" name="numberA" value="0" size="5"></input>
	<select name="operator">
	  <option value ="+">+</option>
	  <option value ="-">-</option>
	  <option value="*">*</option>
	  <option value="/">/</option>
	</select>
	<input type="text" name="numberB" value="0" size="5"></input>
	<br><input type="sumbit" name="sumbit" value="提交"></input>
</form>

<hr>
<jsp:setProperty name="computer" property="*" />
<%
	if (request.getParameter("numberA") != null) {
		out.println("<%= computer.getNumberA() %> <%= computer.getOperator() %> <%= computer.getNumberB() %> = <%= computer.getResult() %> " );
	}
%>


</body>
</html>